package com.tianxiabuyi.model.pojo;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Version;

import com.alibaba.fastjson.annotation.JSONField;
import com.tianxiabuyi.model.base.TXBYObject;

@Entity
@Table(name = "transaction")
public class Transaction extends TXBYObject {
	@Column(name = "pay_uid")
	@JSONField(name = "pay_uid")
	private Integer payUid; // 付款人id
	private String token; // 令牌
	private float price; // 单价
	private Integer amount; // 数量
	private float total; // 总价
	@Column(name = "patient_uid")
	@JSONField(name = "patient_uid")
	private Integer patientUid; // 病人id
	@Column(name = "patient_id")
	@JSONField(name = "patient_id")
	private String patientId; // 就诊卡号
	@Column(name = "patient_name")
	@JSONField(name = "patient_name")
	private String patientName; // 病人姓名
	@Column(name = "card_number")
	@JSONField(name = "card_number")
	private String cardNumber; // 身份证
	private Integer self; // 是否是自己
	@Column(name = "out_trade_no")
	@JSONField(name = "out_trade_no")
	private String outTradeNo; // 订单号
	@Column(name = "transaction_id")
	@JSONField(name = "transaction_id")
	private String transactionId; // 第3方交易号
	@Column(name = "reciept_no")
	@JSONField(name = "reciept_no")
	private String recieptNo; // 医院的单号
	@Column(name = "reciept_type")
	@JSONField(name = "reciept_type")
	private String recieptType; // 医院的单号
	@Column(name = "pay_status")
	@JSONField(name = "pay_status")
	private Integer payStatus; // 付款状态
	@Column(name = "effective_time")
	@JSONField(name = "effective_time")
	private Integer effectiveTime; // 付款有效时间
	@Column(name = "report_need")
	@JSONField(name = "report_need")
	private Integer reportNeed; // 是否需要报告
	@Column(name = "report_state")
	@JSONField(name = "report_state")
	private String reportState; // 报告状态
	@Column(name = "report_access")
	@JSONField(name = "report_access")
	private String reportAccess; // 报告获取途径
	@Column(name = "his_state")
	@JSONField(name = "his_state")
	private String hisState; // his状态
	@Column(name = "his_time")
	@JSONField(name = "his_time")
	private Date hisTime; // his确认时间
	@Column(name = "his_token")
	@JSONField(name = "his_token")
	private String hisToken; // his的令牌（验证码）
	@Column(name = "result_pay")
	@JSONField(name = "result_pay")
	private String resultPay; // 第3方付款的返回结果
	@Column(name = "result_his")
	@JSONField(name = "result_his")
	private String resultHis; // his返回的结果
	@Column(name = "order_id")
	@JSONField(name = "order_id")
	private Integer orderId; // his返回的结果
	private Integer notify = 0; // 微信是否已经通知
	@Version
	@Column(name = "version")
	private Integer version; // 防止重复付款的版本控制

	public Integer getPayUid() {
		return payUid;
	}

	public void setPayUid(Integer payUid) {
		this.payUid = payUid;
	}

	public String getToken() {
		return token;
	}

	public void setToken(String token) {
		this.token = token;
	}

	public float getPrice() {
		return price;
	}

	public void setPrice(float price) {
		this.price = price;
	}

	public Integer getAmount() {
		return amount;
	}

	public void setAmount(Integer amount) {
		this.amount = amount;
	}

	public float getTotal() {
		return total;
	}

	public void setTotal(float total) {
		this.total = total;
	}

	public Integer getPatientUid() {
		return patientUid;
	}

	public void setPatientUid(Integer patientUid) {
		this.patientUid = patientUid;
	}

	public String getPatientId() {
		return patientId;
	}

	public void setPatientId(String patientId) {
		this.patientId = patientId;
	}

	public String getPatientName() {
		return patientName;
	}

	public void setPatientName(String patientName) {
		this.patientName = patientName;
	}

	public Integer getSelf() {
		return self;
	}

	public void setSelf(Integer self) {
		this.self = self;
	}

	public String getOutTradeNo() {
		return outTradeNo;
	}

	public void setOutTradeNo(String outTradeNo) {
		this.outTradeNo = outTradeNo;
	}

	public String getTransactionId() {
		return transactionId;
	}

	public void setTransactionId(String transactionId) {
		this.transactionId = transactionId;
	}

	public String getRecieptNo() {
		return recieptNo;
	}

	public void setRecieptNo(String recieptNo) {
		this.recieptNo = recieptNo;
	}

	public String getRecieptType() {
		return recieptType;
	}

	public void setRecieptType(String recieptType) {
		this.recieptType = recieptType;
	}

	public Integer getPayStatus() {
		return payStatus;
	}

	public void setPayStatus(Integer payStatus) {
		this.payStatus = payStatus;
	}

	public Integer getEffectiveTime() {
		return effectiveTime;
	}

	public void setEffectiveTime(Integer effectiveTime) {
		this.effectiveTime = effectiveTime;
	}

	public String getHisState() {
		return hisState;
	}

	public void setHisState(String hisState) {
		this.hisState = hisState;
	}

	public Date getHisTime() {
		return hisTime;
	}

	public void setHisTime(Date hisTime) {
		this.hisTime = hisTime;
	}

	public String getResultPay() {
		return resultPay;
	}

	public void setResultPay(String resultPay) {
		this.resultPay = resultPay;
	}

	public String getResultHis() {
		return resultHis;
	}

	public void setResultHis(String resultHis) {
		this.resultHis = resultHis;
	}

	public Integer getOrderId() {
		return orderId;
	}

	public void setOrderId(Integer orderId) {
		this.orderId = orderId;
	}

	public String getCardNumber() {
		return cardNumber;
	}

	public void setCardNumber(String cardNumber) {
		this.cardNumber = cardNumber;
	}

	public Integer getReportNeed() {
		return reportNeed;
	}

	public void setReportNeed(Integer reportNeed) {
		this.reportNeed = reportNeed;
	}

	public String getReportState() {
		return reportState;
	}

	public void setReportState(String reportState) {
		this.reportState = reportState;
	}

	public String getReportAccess() {
		return reportAccess;
	}

	public void setReportAccess(String reportAccess) {
		this.reportAccess = reportAccess;
	}

	public String getHisToken() {
		return hisToken;
	}

	public void setHisToken(String hisToken) {
		this.hisToken = hisToken;
	}
	
	public Integer getNotify() {
		return notify;
	}

	public void setNotify(Integer notify) {
		this.notify = notify;
	}

	public Integer getVersion() {
		return version;
	}

	public void setVersion(Integer version) {
		this.version = version;
	}
}
